package cn.wcy.design_patterns.test.Controller.demo1;


import org.springframework.stereotype.Component;

@Component
class ZhangSanHandler extends AbstractHandler {

    @Override
    public String AAA() {
        // 业务逻辑A
        System.out.println("张三完成了AAA任务");
        return "张三完成了AAA任务";
    }

    @Override
    public void afterPropertiesSet() throws Exception {
         Factory.register("张三", this);
    }
}